<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <title>钱包</title>
    <script src="../../web/js/mui.min.js"></script>
    <link href="../../web/css/mui.min.css" rel="stylesheet"/>
    <link rel="stylesheet" type="text/css" href="../../web/css/css.css"/>
    <script type="text/javascript" charset="utf-8">
      	mui.init();
    </script>

	<link rel="stylesheet" type="text/css" href="../../index/css/reset.css"/>
	<link rel="stylesheet" type="text/css" href="../../index/css/style.css"/>
	<script src="https://www.jq22.com/jquery/jquery-1.10.2.js"></script>
	<script src="../../index/laydate/laydate.js"></script>
	<script src="https://www.jq22.com/jquery/echarts-4.2.1.min.js"></script>
	<script src="../../index/js/index.js"></script>
	<script src="../../index/js/jquery.nicescroll.min.js"></script>


	<link rel="shortcut icon" href="favicon.ico"> <link href="/css/bootstrap.min.css?v=3.3.5" rel="stylesheet">
	<link href="/css/font-awesome.min.css?v=4.4.0" rel="stylesheet">

	<link href="/css/animate.min.css" rel="stylesheet">
	<link href="/css/style.min.css?v=4.0.0" rel="stylesheet"><base target="_blank">
	<!-- Sweet Alert -->
	<link href="/css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
	<!-- 弹窗-->
	<script src="../../tanchuan/js/jquery-2.0.0.min.js"></script>
	<link href="../../tanchuan/css/displaystyle.css" rel="stylesheet" />
	<script src="../../tanchuan/js/syntaxhighlighter_3.0.83/shCore.js"></script>
	<script src="../../tanchuan/js/syntaxhighlighter_3.0.83/shBrushJScript.js"></script>
	<link href="../../tanchuan/js/syntaxhighlighter_3.0.83/styles/shCoreRDark.css" rel="stylesheet" />
	<script src="../../tanchuan/js/NZ-Plugin/Js/NZ-Window.min.js"></script>
	<link href="../../tanchuan/js/NZ-Plugin/Css/NZ-Window.min.css" rel="stylesheet" />
	<script src="../../tanchuan/js/NZ-Plugin/Js/NZ-Drag.min.js"></script>
	<script src="/js/bootstrap.min.js?v=3.3.5"></script>
	<script src="/js/plugins/sparkline/jquery.sparkline.min.js"></script>
	<script src="/js/plugins/peity/jquery.peity.min.js"></script>
	<script src="/js/content.min.js?v=1.0.0"></script>
	<script src="/js/demo/peity-demo.min.js"></script>
	<script src="/js/plugins/gritter/jquery.gritter.min.js"></script>
	<script src="/js/plugins/sweetalert/sweetalert.min.js"></script>
</head>
<body>
	<header class="mui-bar mui-bar-nav">
	    <h1 class="mui-title">精研
			<a style="font-size:15px;" href="/web">&nbsp;&nbsp;&nbsp;>切换电脑版</a>
		</h1>
	</header>

	<div class="mui-content" id="container">
			<!--订单量-->
			<div class="main_phone">
				<div class="main_left_phone">
					<!--顶部-->
					<div class="order_list">
						<!-- 上证 -->
						<div class="order">
								<h2 >&nbsp;&nbsp;&nbsp;上证</h2>
								<a th:if="${sh?.szxd} ge 0"  th:text="${sh.szzs}" style="font-size:20px;font-weight:bold;color:red;"/>
								<a th:if="${sh?.szxd} lt 0"  th:text="${sh.szzs}" style="font-size:20px;font-weight:bold;color:green;"/>
						</div>
						<!-- 大盘主力资金 -->
						<div class="orderPhone breathe-btn">
							<h2 class="text-navy " style="max-width: 100%; height: auto;color:red;" >
								<a th:text="${LNQX}"  style="max-width: 100%; height: auto;color: red;" ></a>
							</h2>
							<h4 class="text-danger">
								<a style="font-size:12px;">涨停:&nbsp;</a>
								<a th:text="${todayQinXu.nowZtzs}+'  &nbsp;&nbsp;'" style="max-width: 100%; height: auto;color:red;"/>
								<a style="font-size:12px;">跌停:&nbsp;</a>
								<a th:text="${todayQinXu.nowDtzs}+'  &nbsp;&nbsp;'" style="max-width: 100%; height: auto;color:green;"/>
								<a style="font-size:12px;">上涨:&nbsp;</a>
								<a th:text="${todayQinXu.ztzs}+'  &nbsp;&nbsp;'" style="max-width: 100%; height: auto;color:red;"/>
								<a style="font-size:12px;">下跌:&nbsp;</a>
								<a th:text="${todayQinXu.dtzs}+'  &nbsp;&nbsp;'" style="max-width: 100%; height: auto;color:green;"/>
							</h4>
						</div>
						<!-- 深市 -->
						<div class="order">
								<h2 >&nbsp;&nbsp;&nbsp;深市</h2>
								<a th:if="${sz?.szxd} ge 0"  th:text="${sz.szzs}" style="font-size:20px;font-weight:bold;color:red;"/>
								<a th:if="${sz?.szxd} lt 0"  th:text="${sz.szzs}" style="font-size:20px;font-weight:bold;color:green;"/>
						</div>
					</div>
					<br>
					<!-- 涨跌数（图表） -->
					<div class="home_today_new" >
						<div class="home_list">
							<div class="home_order">
								<div class="home_name">
									上证量能
								</div>
								<div class="home_num jian_num" th:text="${szAndShTotalTradeSum.shTradeSum}+'亿'">
								</div>
							</div>
							<div class="home_order " onclick="openNewWindows('/zhuxian')">
								<div class="home_name "  >
									北上资金
								</div>
								<div th:if="${bszj?.netBuyAmt} ge 0" class="home_num jian_num" th:text="${bszj.netBuyAmt}+'亿'" style="color:red;"> </div>
								<div th:if="${bszj?.netBuyAmt} lt 0" class="home_num jian_num" th:text="${bszj.netBuyAmt}+'亿'" style="color:green;"> </div>
							</div>

							<div class="home_order " onclick="openNewWindows('/zhuxian')">
								<div class="home_name "  >
									A股总量能
								</div>
								<div th:if="${AtotalAmount} ge 9000" class="home_num jian_num" th:text="${AtotalAmount}+'亿'" style="color:red;"></div>
								<div th:if="${AtotalAmount} lt 9000" class="home_num jian_num" th:text="${AtotalAmount}+'亿'" style="color:green;"></div>

							</div>
						</div>
						<div id="home_today_new"></div>
					</div>
				</div>
				</div>
	</div>
	<nav class="mui-bar mui-bar-tab">
		<a class="mui-tab-item mui-active" href="/web">
			<i class="iconfont"><img src="../../web/img/qianbao2.png"/></i>
			<p class="mui-tab-label mui-active">主页</p>
		</a>
		<a class="mui-tab-item" href="/web/hangqing" >
			<i class="iconfont"><img src="../../web/img/hangqing.png"/></i>
			<p class="mui-tab-label">大成交</p>
		</a>
		<a class="mui-tab-item" href="/web/faxian">
			<i class="iconfont"><img src="../../web/img/faxian.png"/></i>
			<p class="mui-tab-label">消息</p>
		</a>
		<a class="mui-tab-item" href="/web/wode">
			<i class="iconfont"><img src="../../web/img/wode.png"/></i>
			<p class="mui-tab-label">我的</p>
		</a>
	</nav>
	<script type="text/javascript">
		mui('body').on('tap','a',function(){
			document.location.href=this.href;
		})
		window.onload = function() {
			var textNavyElements = document.querySelectorAll('.text-navy a');
			textNavyElements.forEach(function(el) {
				var parentWidth = el.parentNode.offsetWidth;
				var currentFontSize = 16; // 初始字体大小
				var缩放因子 = 1; // 缩放因子，用于调整字体大小

				while (el.offsetWidth > parentWidth && currentFontSize > 1) {
					currentFontSize--;
					el.style.fontSize = currentFontSize + 'px';
					缩放因子 = currentFontSize / 16;
				}
			});
		};
	</script>
	<script type="text/javascript">
		var zhangTingList= [[${zhangTingList}]];
		var dieTingList= [[${dieTingList}]];
		var szList= [[${szList}]];
		var xdList= [[${xdList}]];
		var size= [[${size}]];
		var tradeMinutes = [[${objMinutes_}]];
		var yesToDayAmount = [[${objyestoDayAmount_}]];
		var toDayAmount = [[${objToDayAmount_}]];
		//
		var days= [[${days}]];
		var gaoDu= [[${gaoDu}]];

		var myChart2 =echarts.init(document.getElementById('home_today_new'));
		var option2 ={
			backgroundColor: '#1b1e25',
			title: {
				text: '',
			},

			tooltip: {
				enterable:true,
				trigger: 'axis'

			},
			grid: {
				left: '3%',
				right: '3%',
				top: '10%',
				bottom:"2%",
				containLabel: true
			},
			xAxis : [
				{
					axisLine:{
						lineStyle:{
							color:'#3e4148',
							width:1,//这里是为了突出显示加上的
						}
					},
					type : 'category',
					data :  tradeMinutes
				}
			],
			yAxis : [
				{
					splitLine:{
						lineStyle:{
							color: '#21242b',
						}
					},
					type : 'value',
					axisLine:{
						lineStyle:{
							color:'#43484e',
							width:0,//这里是为了突出显示加上的
						}
					}
				}
			],
			series : [
				{
					name:'昨日',
					type:'bar',
					symbol:'none',
					barWidth: '20%',
					data: yesToDayAmount,
					smooth: true,
					itemStyle : {
						color:'#999999'
					},
					areaStyle: {normal: { color: ['rgba(255,255,255,0.1)']}},
				},
				{
					name:'今日',
					type:'bar',
					symbol:'none',
					barWidth: '20%',
					data: toDayAmount,
					smooth: true,
					itemStyle : {
						color:'red'
					},
					areaStyle: {normal: { color: ['rgba(255,255,255,0.1)']}},
				}
			]
		};
	</script>
	<script>

		$(".order_num").each(function(){
			var that=$(this);
			var text1=that.text();
			var text1_1=parseInt(text1);
			var te=formatNum(text1_1+"");
			that.text(te)
		})


		function formatNum(str) {
			var newStr = "";
			var count = 0;
			if (str.indexOf(".") == -1) {
				for (var i = str.length - 1; i >= 0; i--) {
					if (count % 3 == 0 && count != 0) {
						newStr = str.charAt(i) + "," + newStr;
					} else {
						newStr = str.charAt(i) + newStr;
					}
					count++;
				}
				str = newStr;
				return str;
			}

		}

		function chakanxaingxing(object) {
			var code = object.id;
			var url = 'http://stockpage.10jqka.com.cn/' + code;
			$.NZ_Window.show({
				url: url,
				width: 1100,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}
		function stockKanDian(object) {
			var code = object.id;
			var url = 'stockKanDian?code=' + code.replace("kandian_", "");
			$.NZ_Window.show({
				url: url,
				width: 1100,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}

		function stockReDianKanOneHour(object){
			var code=object.id;
			$.NZ_Window.show({
				url: '/ths/stockKanDian?type=oneHour&code='+code,
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}

		function stockReDianKan24Hour(object){
			var code=object.id;
			$.NZ_Window.show({
				url: '/ths/stockKanDian?type=24Hour&code='+code,
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}

		function stockMinutes30(object){
			var code=object.id;
			$.NZ_Window.show({
				url: '/stockMinutes30?code='+code,
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}

		function openUrl(url){
			window.open(url,"_blank");
		}

		function chakanBanKuai(object){
			var code=object.id;
			var url= 'http://quote.eastmoney.com/bk/'+code+'.html#fullScreenChart';
			$.NZ_Window.show({
				url: url,
				width: 1100,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}
		function banKuaiMaoLiLv(object) {
			var code=object.id;
			var url = 'banKuaiMaoLiLv?banKuai='+code;
			$.NZ_Window.show({
				url: url,
				width: 1100,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function openNewWindows(url){
			// var code=object.id;
			// var url= 'http://quote.eastmoney.com/bk/'+code+'.html';
			$.NZ_Window.show({
				url: url,
				width: 1100,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
			// window.open('/stockMinutes?code='+code,'','width=2000,height=1000,left=200,top=300,toolbar=no, status=no, menubar=no, resizable=yes, scrollbars=yes');
		}
		function wtchK(object){
			var code=object.id;
			$.NZ_Window.show({
				url: "https://quote.eastmoney.com/concept2/"+code+".html#fullScreenChart",
				//url: 'https://t.10jqka.com.cn/m/'+code+'/touzi/',
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function wtchInfo(){
			$.NZ_Window.show({
				url: "https://www.yuque.com/yonghengguodu-fohhs/us5yes/badxyrcgm6tw50wg?singleDoc# 《精研 3.0 使用说明》",
				//url: 'https://t.10jqka.com.cn/m/'+code+'/touzi/',
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function querySinaStockInfo(){
			var xhr = new XMLHttpRequest();
			xhr.open('POST', 'http://hq.sinajs.cn/list=s_sh000001', true);
			xhr.setRequestHeader('Referer', 'https://finance.sina.com.cn');
			xhr.onreadystatechange = function () {
				if (xhr.readyState === 4) {
					if (xhr.status === 200) {
						var response = JSON.parse(xhr.responseText);
						console.log(response);
					} else {
						console.log('Error: ' + xhr.status);
					}
				}
			};
			xhr.send();
		}


		function showTag(url){
			$.NZ_Window.show({
				url: url,
				width: 1500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function zuoT(){
			$.NZ_Window.show({
				url: "/zuot/stockKey",
				width: 500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function stockTBykey(object) {
			var code = object.id;
			var url = '/zuot/stockKey?key=' + code.replace("kandian_", "");
			$.NZ_Window.show({
				url: url,
				width: 500,
				height: 1000,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}

		function stockTByIndex(object) {
			var code = object.id;
			var url = '/zuot/index?key=' + code.replace("kandian_", "");
			$.NZ_Window.show({
				url: url,
				width: 500,
				height: 800,
				operate: {
					btn_Close: true, //关闭按钮
					btn_Max: true, //最大化按钮
					btn_Refresh: true, //刷新按钮
					btn_NewWindow: true, //新窗口按钮
					resize: true //调整窗口大小按钮
				}
			});
		}
		$("#sparkline10").sparkline( gaoDu,
				{
					type: "line",
					width: "100%",
					height: "100%",
					lineColor: "#ed5565",
					fillColor: "#ffffff"
				});

	</script>
</body>
</html>